<template>
  <div id="app">
    <deri-header v-if="!isLogin"></deri-header>
    <router-view/>
    <deri-footer v-if="!isLogin"></deri-footer>
  </div>
</template>

<script>

export default {
  data() {
    return {
      isLogin: false
    }
  },
  watch: {
    $route: {
      handler(to) {
        console.log(to)
        if (to.path.includes('login')) {
          this.isLogin = true
        } else {
          this.isLogin = false
        }
      },
      immediate: true,
    },
  },
}
</script>


<style lang="scss">
</style>
